package com.wicket.okrapp.integration.dto;

import com.wicket.okrapp.common.dto.BaseDto;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.util.Date;
import java.util.Objects;

import lombok.Data;

/**
 * @desc FillingIntervalHolidayDto
 * @使用场景
 */
@Data
public class FillingIntervalHolidayDto extends BaseDto implements Serializable {

  /**
   * 周期ID
   */
  @ApiModelProperty("周期ID")
  private String cycleId;

  /**
   * 周期开始时间
   */
  @ApiModelProperty("周期开始时间")
  private Date cycleStartTime;

  /**
   * 周期结束时间
   */
  @ApiModelProperty("周期结束时间")
  private Date cycleEndTime;

  @Override
  public boolean equals(Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;
    if (!super.equals(o)) return false;
    FillingIntervalHolidayDto that = (FillingIntervalHolidayDto) o;
    return (
      cycleId == that.cycleId &&
      cycleStartTime == that.cycleStartTime &&
      cycleEndTime == that.cycleEndTime
    );
  }

  @Override
  public int hashCode() {
    return Objects.hash(
      super.hashCode(),
      cycleId,
      cycleStartTime,
      cycleEndTime
    );
  }

}
